package week3;

import java.util.Scanner;

public class q1 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("身高（单位，m）");
        double height = sc.nextDouble();
        System.out.println("体重（单位，kg）");
        double weight = sc.nextDouble();
        double bmi = weight / (height * height);
        System.out.println("你的bmi值："+bmi);
        if (bmi < 18.5) {
            System.out.println(1);
        } else if (bmi>=18.5&&bmi<25) {
            System.out.println(2);
        }else if (bmi>=25&&bmi<30){
            System.out.println(3);
        }else {
            System.out.println(4);
        }
    }
}
